package base.render;

import java.awt.Color;

public class ColorHandler
{
	public static Color getColor(int par1)
	{
		return new Color(getRed(par1), getGreen(par1), getBlue(par1));
	}
	
	public static int getColorString(int red, int green, int blue)
	{
		return ((red & 0x0FF) << 16) | ((green & 0x0FF) << 8) | (blue & 0x0FF);
	}
	
	public static int getRed(int par1)
	{
		return (par1 >> 16) & 0xFF;
	}
	
	public static int getGreen(int par1)
	{
		return (par1 >> 8) & 0xFF;
	}
	
	public static int getBlue(int par1)
	{
		return par1 & 0xFF;
	}
}